import hashlib


def md5_string(s):
    """生成md5加密"""
    obj = hashlib.md5('dhwadjhfjkwafjawddadf'.encode('utf-8'))
    obj.update(s.encode('utf-8'))
    return obj.hexdigest()


print(md5_string('123456'))